package com.zhongfl.crm.lixiao.batch.jobs;

import com.zhongfl.crm.lixiao.batch.service.LXChannelRevisitLog2BossSyncService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * 励销渠道跟进记录 同步服务
 *
 * @author tiantian
 * @date 2018/7/12 12:19
 */
@Component
@Slf4j
public class LXChannelRevisitLog2BossSyncJob extends JobService {

    @Resource
    private LXChannelRevisitLog2BossSyncService lxChannelRevisitLog2BossSyncService;

    @Override
    public boolean lock() {
        return true;
    }

    @Override
    public void start() throws Exception {

        log.info("潜在渠道 励销跟进记录 同步服务开始");
        lxChannelRevisitLog2BossSyncService.syncRevisitLog("lead",false);
        log.info("签约渠道 励销跟进记录 同步服务结束");

        log.info("潜在渠道 励销跟进记录 同步服务开始");
        lxChannelRevisitLog2BossSyncService.syncRevisitLog("customer",false);
        log.info("签约渠道 励销跟进记录 同步服务结束");

    }
}
